<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;

class AttributeProperty extends Model
{
    public $timestamps = false;

    protected $fillable = ['property_id','attribute_id','type'];

    // 属性
    static public function getPropertyByAttrId($ids,$type='property')
    {
        return self::where('type',$type)->whereIn('attribute_id',$ids)->get(['property_id'])->toArray();
    }
}
